// eslint-disable-next-line import/no-extraneous-dependencies
import loglevel from "loglevel";

export default (off) => {
    if (!off) {
        return;
    }
    console.log = () => {};
    // Switch off log info bellow error level within loglevel used by matrix-js-sdk
    const logger = loglevel.getLogger("matrix");
    logger.setLevel(loglevel.levels.ERROR);
};
